<div class="form">
<div class="table">
<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'product-category-form',
    'enableClientValidation'=>true,
	'enableAjaxValidation'=>true,
    'clientOptions'=>array(
        'validateOnSubmit'=>true,
        'validateOnChange'=>true,
        'validateOnType'=>false,
    ),
)); ?>
	<div class="tr">
		<div class="td"><?= CHtml::label(Yii::t('BackEnd','Parents Category'),'parents'); ?></div>
		<div class="td2">
            <select name="parents" id="parents" class="input">
                <option value="0">----------<?= Yii::t('BackEnd','Choose Product Category'); ?>----------</option>
                <?= ProductCategory::listMenu(0, $menuData); ?>
            </select>
        </div>
		<div class="td3"></div>
	</div>

	<div class="tr">
		<div class="td"><?= $form->labelEx($model,'name'); ?></div>
		<div class="td2"><?= $form->textField($model,'name',array('maxlength'=>50,'class'=>'input')); ?></div>
		<div class="td3"><?= $form->error($model,'name'); ?></div>
	</div>

    <?php if(!$model->isNewRecord) : ?>
	<div class="tr">
		<div class="td"><?= $form->labelEx($model,'status'); ?></div>
		<div class="td2"><?= $form->dropDownList($model,'status',ProductCategory::getStatusArray(),array('class'=>'input')); ?></div>
		<div class="td3"><?= $form->error($model,'status'); ?></div>
	</div>
    <?php endif; ?>

	<div class="tr">
        <div class="td"></div>
		<div class="td2">
            <?= CHtml::submitButton($model->isNewRecord ? Yii::t('BackEnd','Create') : Yii::t('BackEnd','Update'), array('class' => 'button')); ?>
            <?= CHtml::resetButton(Yii::t('BackEnd','Reset'), array('class' => 'button')); ?>
        </div>
        <div class="td3"></div>
	</div>

<?php $this->endWidget(); ?>
</div>
</div>